﻿@model HanGu.Entity.Message
@{
    Layout = null;
    var action = Request["action"];
    var read = action != null && action == "read";
}
<div class="pageContent">
    <form method="post" action="/Message/Default/SMS?OpID=@ViewData["OperateID"]" class="pageForm required-validate"
    onsubmit="return validateCallback(this, navTabAjaxDone);">
    @Html.ValidationSummary(true)
    <div class="pageFormContent" layouth="56">
        @Html.HiddenFor(model => model.ID)
        @Html.HiddenFor(model => model.Type)
        @Html.Hidden("SMS.MemberID", ViewData["membersID"])
        @Html.HiddenFor(model => model.Title)
        @Html.HiddenFor(model => model.GUID)
        @Html.HiddenFor(model => model.Receiver)
        @Html.Hidden("action", "m")
        <p style="width: 100%; height: auto">
            <label>
                接收客户：</label>
            <label>
                @HttpUtility.UrlDecode(ViewData["membersName"] as string, System.Text.Encoding.GetEncoding("UTF-8"))</label>
        </p>
        <p style="width: 100%; height: auto">
            <label>
                接收号码：</label>
            <label>
                @ViewData["tels"]
            </label>
        </p>
        <p>
            <label>
                创建时间：</label>
            @Html.TextBoxFor(model => model.CreateTime, new { @Readonly = "true" })
            @Html.ValidationMessageFor(model => model.CreateTime)
        </p>
        <p>
            <label>
                创建者：</label>
            @Html.TextBoxFor(model => model.Creator, new { @Readonly = "true" })
            @Html.ValidationMessageFor(model => model.Creator)
        </p>
        <p style="width: 100%; height: 200px">
            <label>
                内容：</label>
            @Html.TextAreaFor(model => model.Remark, new { @class = "required", @Style = "width:95%;height:200px" })
            @Html.ValidationMessageFor(model => model.Remark)
        </p>
    </div>
    @if (Request["action"] != "view")
    {
        <div class="formBar">
            <ul>
                @if (!read)
                {
                    <li>
                        <div class="buttonActive">
                            <div class="buttonContent">
                                <button type="submit">
                                    提交</button></div>
                        </div>
                    </li>
                }
                <li>
                    <div class="button">
                        <div class="buttonContent">
                            <button type="button" class="close">
                                取消</button></div>
                    </div>
                </li>
            </ul>
        </div>
    }
    </form>
</div>
